Note: This is a legacy endpoint, consider using this endpoint instead. The endpoint will continue to function as documented.
Get continuous safety events. The safety activity event feed offers a change-log for safety events. Use this endpoint to subscribe to safety event changes. See documentation below for all supported change-log types.
| ActivityType | Description |
|---|---|
| CreateSafetyEventActivityType | a new safety event is processed by Samsara |
| BehaviorLabelActivityType | a label is added or removed from a safety event |
| CoachingStateActivityType | a safety event coaching state is updated |
Rate limit: 5 requests/sec (learn more about rate limits here).
To use this endpoint, select Read Safety Events & Scores under the Safety & Cameras category when creating or editing an API token. Learn More.
Submit Feedback: Likes, dislikes, and API feature requests should be filed as feedback in our API feedback form. If you encountered an issue or noticed inaccuracies in the API documentation, please submit a case to our support team.
curl --request GET \
--url https://api.samsara.com/fleet/safety-events/audit-logs/feed \
--header 'Authorization: Bearer <token>'{
"data": [
{
"id": "1622151765-212014918174029-1550954461759",
"safetyEvent": {
"behaviorLabels": [
{
"name": "Acceleration",
"type": "Acceleration"
}
],
"driver": {
"id": "0987"
},
"id": "212014918174029-1550954461759",
"time": "2019-06-13T19:08:25.455Z",
"vehicle": {
"id": "1234"
}
},
"time": "2019-10-12T07:20:50.52Z",
"type": "CreateSafetyEventActivityType"
}
],
"pagination": {
"endCursor": "MjkY",
"hasNextPage": true
}
}Documentation Index
Fetch the complete documentation index at: https://samsara-showcase.mintlify.app/llms.txt
Use this file to discover all available pages before exploring further.
Bearer authentication header of the form Bearer <token>, where <token> is your auth token.
If specified, this should be the endCursor value from the previous page of results. When present, this request will return the next page of results that occur immediately after the previous page of results.
A start time in RFC 3339 format. Defaults to now if not provided. Millisecond precision and timezones are supported. (Examples: 2019-06-13T19:08:25Z, 2019-06-13T19:08:25.455Z, OR 2015-09-15T14:00:12-04:00).
curl --request GET \
--url https://api.samsara.com/fleet/safety-events/audit-logs/feed \
--header 'Authorization: Bearer <token>'{
"data": [
{
"id": "1622151765-212014918174029-1550954461759",
"safetyEvent": {
"behaviorLabels": [
{
"name": "Acceleration",
"type": "Acceleration"
}
],
"driver": {
"id": "0987"
},
"id": "212014918174029-1550954461759",
"time": "2019-06-13T19:08:25.455Z",
"vehicle": {
"id": "1234"
}
},
"time": "2019-10-12T07:20:50.52Z",
"type": "CreateSafetyEventActivityType"
}
],
"pagination": {
"endCursor": "MjkY",
"hasNextPage": true
}
}